import axiosInstance from '@/apis/request';  
import type { AxiosResponse } from "axios"

// 定义响应数据的类型  
interface User {  
  date: string,
  name: string,
  address: string,
  id: number
}
interface requestParams {
  name:string, 
  date:string
}
export const fetchUsers = async (params: requestParams ) => {
  const response = await axiosInstance.post<User[], AxiosResponse<User[]>>('/users', params);
  return response
}